import Vue from 'vue'
import VueRouter from 'vue-router'
import HomeView from '../views/HomeView.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'home',
    component: HomeView
  },
  {
    path: '/about',
    name: 'about',
    
    component: () => import('../views/AboutView.vue')
  },
  {
    path: '/login',
    name: 'login',
    
    component: () => import('../views/login.vue')
  },
  {
    path: '/publish',
    name: 'publish',
    
    component: () => import('../views/publish.vue')
  },
  {
    path: '/user_edit',
    name: 'user_edit',
    
    component: () => import('../views/user_edit.vue')
  },
  {
    path: '/my',
    name: 'my',
    
    component: () => import('../views/my.vue')
  },
  {
    path: '/search',
    name: 'search',
    
    component: () => import('../views/search.vue')
  },
  {
    path: '/article',
    name: 'article',
    
    component: () => import('../views/article.vue')
  },
  {
    path: '/reg',
    name: 'reg',
    
    component: () => import('../views/reg.vue')
  },
]

const router = new VueRouter({
  routes
})

export default router
